package beans;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * Creared with IntelliJ IDEA.
 * Description:
 * User:yxd
 * Date:2022-07-14
 * Time:17:07
 */
@Component
public class BeanScope1 {
    @Autowired
    private User userinfo;

    public User getUser(){
        User user = userinfo;
        user.setName("张三");
        return user;
    }
}
